Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix sdbus::ObjectPath when checking signals object_path #1711

Merged

Conversation

kontura
Copy link
Contributor

@kontura kontura commented Sep 19, 2024

  1. Fix deserialization when checking signals object_path.

    Since dnfdaemon: Correct D-Bus signal argument type #1679 sdbus::ObjectPath is send over to the client not std::string.

    This was causing the check signature_valid(sdbus::Signal &) to crash, the client callback ended and the server kept waiting for result of the key_import userconfirm.

    (I believe we should somehow handle when DbusCallback::signature_valid() returns false but I am not sure what would be the best approach. At least logging the event would be good (through the context?).)

  2. The other commit fixes a bug for dnf5daemon offline transactions, analogous to dnf5: Run transaction test for offline transactions #1672.

@kontura kontura marked this pull request as draft September 19, 2024 10:00
Since rpm-software-management#1679
`sdbus::ObjectPath` is send over to the client not std::string.

This was causing the check `signature_valid(sdbus::Signal &)` to crash,
the client callback ended and the server kept waiting for result
of the `key_import` userconfirm.
@kontura kontura force-pushed the dnf5daemon-client-signature-valid branch from 5bafca1 to 30c7697 Compare September 20, 2024 04:42
@kontura kontura changed the title Fix comparison when checking signals object_path Fix sdbus::ObjectPath when checking signals object_path Sep 20, 2024
A serialized offline transaction consists only of local packages
downloaded to the `<system state dir>/offline` location. Unfortunately,
PGP checks for these packages are disabled by default due to the
`localpkg_gpgcheck` option default value.
Instead of testing the serialized transaction, this patch performs an
RPM transaction test on the originally resolved transaction, which still
retains information about the repositories from which the packages were
downloaded.
This approach also saves time required for deserialization and resolving
the testing transaction.

This ports the fix from rpm-software-management#1672
to dnf5daemon.
@kontura kontura marked this pull request as ready for review September 20, 2024 06:30
Copy link
Member

@m-blaha m-blaha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@m-blaha m-blaha added this pull request to the merge queue Sep 20, 2024
Merged via the queue into rpm-software-management:main with commit 799a90b Sep 20, 2024
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants